/*
 *===================================================================
 *
 *          Name: global.h
 *        Create: Fri 20 Jul 2012 02:58:02 PM CST
 *
 *   Discription: 
 *       Version: 1.0.0
 *
 *        Author: yuwei.zhang
 *         Email: yuwei.zhang@besovideo.com
 *
 *===================================================================
 */
#ifndef  __GLOBAL_H
#define  __GLOBAL_H

#ifdef __cplusplus
#define EXTERN_C_START extern "C" {
#define EXTERN_C_END   }
#define EXTERN_C_FUNC  extern "C"
#else
#define EXTERN_C_START 
#define EXTERN_C_END   
#define EXTERN_C_FUNC  
#endif

#define PRINT_MESSG             // print message for user success
#define PRINT_ERROR

#ifdef PRINT_MESSG
  #define JKMSG(fmt, args...)                  \
    do{                                       \
	    printf("[%3d:%s()@%s] ==> ", __LINE__, __func__, __FILE__);     \
	    printf(fmt, ##args);                      \
    }while(0)
#else
  #define JKMSG(fmt, args...)
#endif				// PRINT_MESSG
#ifdef PRINT_ERROR
    #define JKERR(fmt, args...)           \
      do {                         \
	    printf("[ERROR][%3d:%s()@%s] ==> ", __LINE__, __func__, __FILE__);     \
	    printf(fmt, ##args);                      \
    }while(0)
#else
    #define JKERR(fmt, args...)
#endif


#endif

/*=============== End of file: global.h =====================*/

